package com.aiguigu.lottery.prize.mapper;

import com.aiguigu.lottery.common.entity.UserEntity;
import org.apache.ibatis.annotations.*;

@Mapper
public interface UserMapper {
    
    /**
     * 根据用户名查询用户
     */
    @Select("SELECT * FROM emp WHERE username = #{username}")
    UserEntity findByUsername(@Param("username") String username);
    
    /**
     * 根据ID查询用户
     */
    @Select("SELECT * FROM emp WHERE id = #{id}")
    UserEntity findById(@Param("id") Integer id);
}